package sebastiankerckhof.scene;

import sebastiankerckhof.helper.MathHelper;
import sebastiankerckhof.structure.math.Point3f;
import sebastiankerckhof.structure.math.Vector3f;

public class Camera {
	
	public Point3f e;
	public Vector3f u;
	public Vector3f v;
	public Vector3f w;
	public float fovy;
	
	
	public Camera(Point3f e, Vector3f w, Vector3f v, float fovy){

		this.e = e;
		
		Vector3f[] orthoBase = MathHelper.createOrthoBase(w.negative(), v);
		this.w = orthoBase[0];
		this.u = orthoBase[1];
		this.v = orthoBase[2];
		
		this.fovy = fovy;
	}
	
	public String toString(){
		return "e: "+e+"\nu:"+u+"\nv:"+v+"\nw:"+w+"\nfovy:"+fovy;
	}
	
}
